docs: update Dockerfile
authorIgor Opaniuk <igor.opaniuk@foundries.io>
Wed, 15 Jan 2025 16:08:51 +0000 (17:08 +0100)
committerIgor Opaniuk <igor.opaniuk@foundries.io>
Wed, 15 Jan 2025 16:16:03 +0000 (17:16 +0100)
Fix issues in Dockerfile:
1. Update Fedora image to the latest version 41, otherwise docker build
   fails with an error:

   Step 1/7 : FROM registry.fedoraproject.org/fedora:28
   manifest for registry.fedoraproject.org/fedora:28 not found: manifest unknown: manifest unknown

2. Force install python3-yaml package, as it's required for running some
   tests. For example, tests/test-remote-headers.sh will fail without
   it:

   V=$($CMD_PREFIX ostree --version | \
       python3 -c 'import sys, yaml; print(yaml.safe_load(sys.stdin)["libostree"]["Version"])')
   Traceback (most recent call last):
   File "<string>", line 1, in <module>
    import sys, yaml; print(yaml.safe_load(sys.stdin)["libostree"]["Version"])
    ^^^^^^^^^^^^^^^^
   ModuleNotFoundError: No module named 'yaml'

With these fixes `make check` executes successfully in a container:
============================================================================
Testsuite summary for libostree 2024.11
============================================================================
 TOTAL: 935
 PASS:  888
 SKIP:  47
 XFAIL: 0
 FAIL:  0
 XPASS: 0
 ERROR: 0

Signed-off-by: Igor Opaniuk <igor.opaniuk@foundries.io>
docs/contributing-tutorial.md

index e6172cfc9c464f53cc22de6fe3c8bf58c56d9303..0bcf8feb5f35b9683eb2ef2cc6c812cbe0c0bb78 100644 (file)
@@ -114,11 +114,11 @@ The example below uses Docker to manage containers. Save the contents of this **
 
 ```bash
 # this pulls the fedora 28 image
-FROM registry.fedoraproject.org/fedora:28
+FROM registry.fedoraproject.org/fedora:41
 
 # install ostree dependencies
 RUN dnf update -y && \
-    dnf -y install @buildsys-build dnf-plugins-core  && \
+    dnf -y install @buildsys-build dnf-plugins-core python3-yaml && \
     dnf -y builddep ostree  && \
     dnf clean all